package java8_23;

/**
 * @author oldliu
 * @since 1.0
 */
public class Dog {
    String name;//包权限
    public Dog(){

    }
     public Dog(String n){
         name=n;
     }

    public void bite(Ciwei c) {
        System.out.println(name+"咬了"+c.name+"，无从下口");
    }

    public void bite(KindMan m) {
        //。。。说明一下
        System.out.println(name+"咬了"+m.name+",留下千古恶名");
    }
    //一个类的两个对象
    public void bite(Dog d) {
        System.out.println(name+"咬了"+d.name+",咬下一嘴毛");
    }

    public void show(){
        System.out.println("小狗名叫："+name);
    }
}
